<template>
  <div>
    <table border="1" cellspacing="1">
      <tr>
        <td>年纪</td>
        <td colspan="3">课程</td>

      </tr>
      <tr v-for="i in stu">
        <td>{{i.name}}</td>
        <td colspan="3" v-for="j in i.nj">{{j.name}}</td>
      </tr>

    </table>

  </div>
</template>

<script>
export default {
  name: "kecheng",
  data() {
    return {
      stu: []
    }
  },
  methods: {
    get_stu() {
      this.$axios.get('nian/')
        .then(res => {
          this.stu = res.data.list
        })
    }
  },
  mounted() {
    this.get_stu()
  }
}
</script>

<style scoped>

</style>
